<!DOCTYPE html>
<!-- MUNS copyright, 2010 @author xkx-->
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
		<title>Role Call Test</title>
		
		<link rel="stylesheet" href="core.css" />
		
		<script src="libs/mootools-1.2-core.js"></script>
        <script src="libs/mootools-1.2-more.js"></script>
		<script src="muns.js"></script>
		<script src="rollcall.js"></script>
		
	</head>
	<body>
		<h1>Role Call Test</h1>
		<div style="visibility:hidden;" id="rollcall-area"><table border="1">
			<tr>
				<td><div id ="nations-area" style="height:20em;overflow-x:hidden;overflow-y:scroll"><table border="1" id="nations-table" style="font-size:20px;text-align:left;"></table></div>
				</td>
				<td style="width:20em;vertical-align:middle;">
					<div id="message" class="triangle-isosceles"><div style="text-align:center"><img id="lastnimg" class="p"/><span id="lastnname"></span> is <span id="lasttf"></span></div>
						<div style="text-align:right"><button id="cancellast">cancel</button><button id="recall">reRoleCall</button></div>
					</div><br/>
					<p style="text-align:center"><img id="nationimg" width="48" height="48"/></p><h1 id="nationname" class="nationname"></h1><br/>
					<div id="rollcall-buttons" style="text-align:center"><button id="present">present</button><button id="absent">absent</button></div><hr/>
					<div id="rollcall-status-area">
							<span>Present:</span><span class="present-num"></span><br/>
							<span>Absent:</span><span class="absent-num"></span><br/>
							<span>Reach quorum:</span><span class="is-reachq"></span><br/>
							<span>20%:</span><span class="n20"></span><br/>
							<span>50%+1:</span><span class="n50"></span><br/>
							<span>2/3:</span><span class="n66"></span><br/>
					</div>
				</td>
			</tr>
		</table></div>

		<script>
			window.addEvent('domready',function(){therollcall = new MUN.module.rollcall(document.getElementsByTagName('body')[0],MUN.util.nation_names,"check");therollcall.init();});
			
/*
			function addnation()
			{
				var addnations = addnation.getValues();
				try {
					for (var i=0;i<addnations.length;i++) 
					{
					var thenation = addnations[i][1];
					if(nations.indexOf(thenation) != -1)
					{
						if (calllist[thenation] != 1) 
						{
							calllist[thenation] = 1;
							presentnum++;
							calc();
							// !! add also announce!
						}
						else throw new Error("The nation " + thenation + " is already here.");
					}
					else
					{
						throw new Error("There is not such a nation in this conference.Please check your input.");
					}
					}
				}
				catch(e)
				{
					alert(e.message);
				}
			}
			*/
		</script>
	</body>
</html>
